package View;

import javax.swing.*;
import javax.swing.GroupLayout.Alignment;

import java.awt.Font;
import java.awt.event.ActionListener;

import javax.swing.LayoutStyle.ComponentPlacement;

import Controller.StarterController;

public class StartFrame extends JFrame{
	
	public JButton btnAap = new JButton("Aap");
	public JLabel lblKiesEenDier = new JLabel("Kies een dier om mee te spelen");
	
	public StartFrame(){
		setTitle("Menu");
		setBounds(450, 220, 450, 300);
		
		
		lblKiesEenDier.setFont(new Font("Tahoma", Font.ITALIC, 15));
		
		JLabel lblAapFoto = new JLabel("");
		lblAapFoto.setIcon(new ImageIcon(StartFrame.class.getResource("/img/aap.png")));
		
		
		
		
		
		
		
		GroupLayout groupLayout = new GroupLayout(getContentPane());
		groupLayout.setHorizontalGroup(
			groupLayout.createParallelGroup(Alignment.TRAILING)
				.addGroup(groupLayout.createSequentialGroup()
					.addContainerGap()
					.addComponent(lblAapFoto, GroupLayout.PREFERRED_SIZE, 137, GroupLayout.PREFERRED_SIZE)
					.addPreferredGap(ComponentPlacement.RELATED)
					.addGroup(groupLayout.createParallelGroup(Alignment.LEADING)
						.addComponent(btnAap, GroupLayout.PREFERRED_SIZE, 99, GroupLayout.PREFERRED_SIZE)
						.addComponent(lblKiesEenDier, GroupLayout.PREFERRED_SIZE, 218, GroupLayout.PREFERRED_SIZE))
					.addGap(179))
		);
		groupLayout.setVerticalGroup(
			groupLayout.createParallelGroup(Alignment.LEADING)
				.addGroup(groupLayout.createSequentialGroup()
					.addContainerGap()
					.addGroup(groupLayout.createParallelGroup(Alignment.LEADING)
						.addComponent(lblAapFoto, GroupLayout.PREFERRED_SIZE, 209, GroupLayout.PREFERRED_SIZE)
						.addGroup(groupLayout.createSequentialGroup()
							.addComponent(lblKiesEenDier)
							.addGap(11)
							.addComponent(btnAap)))
					.addContainerGap(41, Short.MAX_VALUE))
		);
		getContentPane().setLayout(groupLayout);
		
		btnAap.addActionListener((ActionListener) new StarterController());
		btnAap.setActionCommand("KiesAap");
	}
}
